package com.example.android.commitcontent.ime.cores.utils;

import android.util.Log;

public class LogHelper {
    private static final String TAG = "Xu";

    public static void e(Object o) {
        Log.e(generateTag(), o.toString());
    }

    private static String generateTag() {
        StackTraceElement stackTraceElement = new Throwable().getStackTrace()[2];
        return String.format("%s:%s.%s()->line:%s",
                TAG, stackTraceElement.getFileName(),
                stackTraceElement.getMethodName(),
                stackTraceElement.getLineNumber());
    }
}
